import { Component, OnInit, Input, OnChanges, SimpleChanges, Output, EventEmitter } from '@angular/core';
import { Examination } from '../../entity/Examination';

@Component({
  selector: 'app-programme-questions',
  templateUrl: './programme-questions.component.html',
  styleUrls: ['./programme-questions.component.css']
})
export class ProgrammeQuestionsComponent implements OnInit {
  @Input() item: Examination;
  @Input() userExam: Examination;
  @Output() userExamChange: EventEmitter<Examination> = new EventEmitter<Examination>();

  constructor() { }

  ngOnInit() {
  }

  customChange(value: any) {
    this.userExam.answer1 = value;
    this.userExamChange.emit(this.userExam);
  }
}
